package com.example.demo.listener;

import com.example.demo.entity.Address;
import org.springframework.context.event.EventListener;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Component;

@Component
public class Publish {

    @Async
    @EventListener
    public void process(Address address){
        System.out.println(address);
    }
}
